//
//  SliderCollectionViewCell.swift
//  Nahuo
//
//  Created by zang qilong on 2017/5/12.
//  Copyright © 2017年 zang qilong. All rights reserved.
//

import UIKit
import RxCocoa

class SliderCollectionViewCell: UICollectionViewCell {

    @IBOutlet weak var categoryLabel: UILabel!
    override func awakeFromNib() {
        super.awakeFromNib()
        categoryLabel.backgroundColor = UIColor.white
        categoryLabel.font = UIFont.pingfangRegularFont(size: 15)
        categoryLabel.textColor = UIColor.titleColor()
        categoryLabel.layer.cornerRadius = 12
        categoryLabel.layer.masksToBounds = true
    }
    
    override var isSelected: Bool {

        didSet {
            if isSelected {
                categoryLabel.backgroundColor = UIColor.appThemeColor()
                categoryLabel.textColor = UIColor.white
            }else {
                categoryLabel.backgroundColor = UIColor.white
                categoryLabel.textColor = UIColor.titleColor()
            }
        }
    }
}
